package g11.model;

import java.io.Serializable;
import java.sql.Date;

public class Appointment implements Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = -1128100669553688318L;

	private Integer appointmentId;
	private Patient patient;
	private Employee doctor;
	private Date appointmentDate;
	private String startTime;
	private String endTime;
	private byte status;
	private String location;

	public int getAppointmentId() {
		return appointmentId;
	}

	public void setAppointmentId(Integer appointmentId) {
		this.appointmentId = appointmentId;
	}

	public Patient getPatient() {
		return patient;
	}

	public void setPatient(Patient patient) {
		this.patient = patient;
	}

	public Employee getDoctor() {
		return doctor;
	}

	public void setDoctor(Employee doctor) {
		this.doctor = doctor;
	}

	public Date getAppointmentDate() {
		return appointmentDate;
	}

	public void setAppointmentDate(Date appointmentDate) {
		this.appointmentDate = appointmentDate;
	}

	public String getStartTime() {
		return startTime;
	}

	public void setStartTime(String startTime) {
		this.startTime = startTime;
	}

	public String getEndTime() {
		return endTime;
	}

	public void setEndTime(String endTime) {
		this.endTime = endTime;
	}

	public byte getStatus() {
		return status;
	}

	public void setStatus(byte status) {
		this.status = status;
	}

	public String getLocation() {
		return location;
	}

	public void setLocation(String location) {
		this.location = location;
	}

	public static long getSerialversionuid() {
		return serialVersionUID;
	}

	@Override
	public boolean equals(Object obj) {
		/*
		 * add by Fern
		 */
		Appointment other = (Appointment) obj;
		if (this.appointmentId == other.appointmentId) {
			return true;
		} else

			return false;
	}

	@Override
	public String toString() {
		return "Appointment [appointmentId=" + appointmentId + ", patient="
				+ patient + ", doctor=" + doctor + ", appointmentDate="
				+ appointmentDate + ", startTime=" + startTime + ", endTime="
				+ endTime + ", status=" + status + ", location=" + location
				+ "]";
	}

}
